class TutorialController < ApplicationController
	layout 'cleanFacebook'
	def index
		logger.error " Hello Sport"
		
	#Basketball
    	 @sportBasketball = Sport.find(3)
    # exclude matches that have been bet on

      limit =  1
      @basketballMatchOfTheDay = current_user.matches.friends_scope.scoped(
        :order=>"friends_count DESC,#{Match.table_name}.comment_count DESC"
      ).normal.except_placed(current_user).paginate :per_page=>limit,
        :page=>params[:page],
        :conditions=>["sport_id = ?",@sportBasketball.id]



		#Soccer  	
    	 @sportSoccer = Sport.find(4)
    # exclude matches that have been bet on

      limit =  1
      @soccerMatchOfTheDay = current_user.matches.friends_scope.scoped(
        :order=>"friends_count DESC,#{Match.table_name}.comment_count DESC"
      ).normal.except_placed(current_user).paginate :per_page=>limit,
        :page=>params[:page],
        :conditions=>["sport_id = ?",@sportSoccer.id]


    end 
        
           
end